package values.map
{
import flash.events.EventDispatcher;

import isoengine.interfaces.IMapObjectData;

import mx.utils.UIDUtil;

/**
 * MapObjectValue
 * @author jliang
 *
 */
public class MapObjectValue extends EventDispatcher implements IMapObjectData
{
	protected var _uid:String = UIDUtil.createUID();
	
	public function get uid():String
	{
		return _uid;
	}
	
	public function get type():String
	{
		return "tile";
	}
	
	[Data(type="field", mapping="@classRef")]
	public var classRef:String;
	
	public var objectClassRef:Class;
	
	protected var _width:int;
	
	public function get width():int
	{
		return _width;
	}
	
	[Data(type="field", mapping="@width")]
	public function set width(value:int):void
	{
		_width = value;
	}
	
	protected var _height:int;
	
	public function get height():int
	{
		return _height;
	}
	
	[Data(type="field", mapping="@width")]
	public function set height(value:int):void
	{
		_height = value;
	}
	
	protected var _x:int;

	public function get x():int
	{
		return _x;
	}
	
	[Data(type="field", mapping="@x")]
	public function set x(value:int):void
	{
		_x = value;
	}
	
	protected var _y:int;

	public function get y():int
	{
		return _y;
	}
	
	[Data(type="field", mapping="@y")]
	public function set y(value:int):void
	{
		_y = value;
	}
	
	protected var _walkable:Boolean;

	public function get walkable():Boolean
	{
		return _walkable;
	}
	
	[Data(type="field", mapping="@walkable")]
	public function set walkable(value:Boolean):void
	{
		_walkable = value;
	}
	
	protected var _direction:int;
	
	public function get direction():int
	{
		return _direction;
	}
	
	[Data(type="field", mapping="@direction")]
	public function set direction(value:int):void
	{
		_direction = value;
	}
	
	public function dispose():void
	{
		
	}

}
}




